<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
  <title>$Title$</title>
</head>
<script src="js/jquery-3.7.1.js"></script>
<script>
  $(function () {
    $("#btn").click(function (){
      /*var obj = {
        "id":1,
        "name":"李四",
        "age":14
      }*/
      $.ajax({
        url:"/getUserList",
        // data:JSON.stringify(obj),
        contentType:"application/json;charset=UTF-8",
        type:"post",
        dataType:"json",
        success:function (res){
          console.log(res);
        }
      })
    })
  })
</script>
<body>
<%--    <button id="btn">按钮</button>--%>
<button onclick="window.location.href='/getUserList'">按钮</button>

</body>
</html>